projects
/
project
/
bcm63xx
/
u-boot.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
282685e
)
usb: dwc2: simplify wait_for_chhltd
author
Stephen Warren
<
[email protected]
>
Sun, 8 Mar 2015 05:48:55 +0000
(22:48 -0700)
committer
Marek Vasut
<
[email protected]
>
Tue, 14 Apr 2015 03:47:58 +0000
(
05:47
+0200)
toggle is never NULL. Simplify the code by removing handling of when it
is NULL.
Signed-off-by: Stephen Warren <
[email protected]
>
drivers/usb/host/dwc2.c
patch
|
blob
|
history
diff --git
a/drivers/usb/host/dwc2.c
b/drivers/usb/host/dwc2.c
index e8a7e713c87f46c09ce1e0cea9ae465d3ec5ba18..5a1c44a8fb757367bbfbbc65e7d327b29b20f709 100644
(file)
--- a/
drivers/usb/host/dwc2.c
+++ b/
drivers/usb/host/dwc2.c
@@
-724,11
+724,9
@@
int wait_for_chhltd(uint32_t *sub, int *toggle)
hctsiz = readl(&hc_regs->hctsiz);
*sub = (hctsiz & DWC2_HCTSIZ_XFERSIZE_MASK) >>
DWC2_HCTSIZ_XFERSIZE_OFFSET;
- if (toggle)
- *toggle = (hctsiz & DWC2_HCTSIZ_PID_MASK) >>
- DWC2_HCTSIZ_PID_OFFSET;
+ *toggle = (hctsiz & DWC2_HCTSIZ_PID_MASK) >> DWC2_HCTSIZ_PID_OFFSET;
- debug("%s: sub=%u toggle=%d\n", __func__, *sub,
toggle ? *toggle : -1
);
+ debug("%s: sub=%u toggle=%d\n", __func__, *sub,
*toggle
);
return 0;
}